From: Miles Bader Date: Mon, 8 Jul 2002 08:45:00 +0000 (+0000) Subject: (comint-dynamic-list-completions): Sort COMPLETIONS before first use. X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1~1^2~31804 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:/?a=commitdiff_plain;h=0edf66e1940feab4574306f1050221396b5db363;p=emacs.git (comint-dynamic-list-completions): Sort COMPLETIONS before first use. --- diff --git a/lisp/comint.el b/lisp/comint.el index 3c0be25c199..e7d038e668d 100644 --- a/lisp/comint.el +++ b/lisp/comint.el @@ -2807,6 +2807,7 @@ See also `comint-dynamic-complete-filename'." "List in help buffer sorted COMPLETIONS. Typing SPC flushes the help buffer." (let ((window (get-buffer-window "*Completions*"))) + (setq completions (sort completions 'string-lessp)) (if (and (eq last-command this-command) window (window-live-p window) (window-buffer window) (buffer-name (window-buffer window)) @@ -2833,7 +2834,7 @@ Typing SPC flushes the help buffer." (let ((conf (current-window-configuration))) (with-output-to-temp-buffer "*Completions*" - (display-completion-list (sort completions 'string-lessp))) + (display-completion-list completions)) (message "Type space to flush; repeat completion command to scroll") (let (key first) (if (save-excursion